package com.zhuoyian.analysis;

import com.zhuoyian.analysis.util.AppUtils;
import com.zhuoyian.analysis.util.EncodeUtil;

import android.content.Context;

public class Analysis {
	public static String imsi;
	public static String imei;
	public static String productId;
	public static String productName;
	public static int isRoot;
	public static int networkType;

	
	public static void init(Context context){
		imsi =AppUtils.getIMSI(context);
		imei =AppUtils.getIMEI(context);
		productId =AppUtils.getRawFileContent(context, "p");
		productName = EncodeUtil.encodeUTF8(AppUtils.getAppName(context));
		isRoot = AppUtils.isDeviceRooted();
		networkType =AppUtils.getCurrentNetType(context);
	}
	
	
	/**
	 * 浏览器数据分析
	 * @return
	 */
	public static BrowserAnalysis getBrowserAnalysis(){
		return BrowserAnalysis.getInstance();
	}
	
	/**
	 * 更新分析
	 * @return
	 */
	public static UpdateAnalysis getUpdateAnalysis(){
		return UpdateAnalysis.getInstance();
	}
}
